import request from '@/utils/request'

// 查询用户列表
export function listAccount(query) {
  return request({
    url: '/common/accountUser/rel/list',
    method: 'get',
    params: query
  })
}

// 修改别名
export function updateAlias(data) {
  return request({
    url: '/common/accountUser/rel/updateAlias',
    method: 'get',
    params: data
  })
}

// 添加或修改人员
export function updateUser(data) {
  return request({
    url: '/common/accountUser/rel/add',
    method: 'post',
    data: data
  })
}

// 批量绑定人员
export function batchBindUser (params) {
  return request({
    url: '/common/accountUser/rel/batchUpdateAlias',
    method: 'get',
    params: params
  })
}

// 批量绑定人员
export function batchBindProduct (params) {
  return request({
    url: '/common/accountUser/rel/batchBindProduct',
    method: 'get',
    params: params
  })
}
